fromOrder=$1
toOrder=$2

for iarg in $*; do
    CLIinputs[$argCounter]=$iarg
    

    option=`echo "$iarg" | cut -d"=" -f1`

    if [ "$option" == "--from" ]; then
	
	fromOrder=`echo "$iarg" | cut -d"=" -f2`
    fi
    if [ "$option" == "--to" ]; then
	
	toOrder=`echo "$iarg" | cut -d"=" -f2`
    fi
done

if [ -z "$fromOrder" ]; then
	echo "empty fromOrder"
	exit
fi

if [ -z "$toOrder" ]; then
	echo "empty toOrder"
	exit
fi

	echo -e "will copy the card from " $fromOrder
	echo -e "will copy the card to " $toOrder

cp -v ../tt_"$fromOrder"_production/input.DAT .
set_mcfm_parameter.sh order \'"$toOrder"\' --file=input.DAT
cp -v ../tt_"$fromOrder"_production/input.DAT.base .
set_mcfm_parameter.sh order \'"$toOrder"\' --file=input.DAT.base
